package com.woniu.service;


import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.woniu.entity.ExpenseDetail;

import java.util.List;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author hyl
 * @since 2022-08-28
 */
public interface IExpenseDetailService extends IService<ExpenseDetail> {


    //全查
   List<ExpenseDetail> getAll();


    //根据报销单号查询
    //EDID -->exp_detail_id
    List<ExpenseDetail> getByEDId(int edid);


    //根据报销类别号查询
    //EID -->exp_id
    List<ExpenseDetail> getByEid(int eid);


    //根据银行账号查询
    //BID -->bank_id
    List<ExpenseDetail> getByBid(int bid);


    //根据部门ID查询
    //DID -->dept_id
    List<ExpenseDetail> getByDid(int did);


    //根据报销时间查询支持模糊查询
    //EDate -->exp_date
    List<ExpenseDetail> getByEDate(String edate);

    //添加报销单
    //EDetail-->Expense_Detail
    void addEDetail(ExpenseDetail eDetail);

    //审批（未通过）
    //EDID -->exp_detail_id
    //EFBack -->expFeedback
    void unpass(int edid,String efback);


   //审批（通过）
   //EDID -->exp_detail_id
   //EFBack -->expFeedback
   void pass(int edid,String efback);

   //多添加查询
    List<ExpenseDetail> getByCondition(ExpenseDetail expenseDetail);

    //多条件分页查询
    Page<ExpenseDetail> getByConditionWithPage(Integer p, Integer pageSize, ExpenseDetail expenseDetail);

    //根据uid分页查询所有
    Page<ExpenseDetail> myListWithPage(Integer p, Integer pageSize,Integer uid);
}
